package icu.sehnen.service.impl;

import icu.sehnen.mapper.CoachMapper;
import icu.sehnen.model.CoachModel;
import icu.sehnen.service.CoachService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class CoachServiceImpl implements CoachService {
    @Autowired
    CoachMapper coachMapper;
    @Override
    public List<CoachModel> findAll() {
    return  coachMapper.findAll();
    }

    @Override
    public void add(CoachModel coachModel) {
        coachMapper.add(coachModel);
    }

    @Override
    public void update(CoachModel coachModel) {
        coachMapper.update(coachModel);
    }

    @Override
    public CoachModel find(Long id) {
       return  coachMapper.find(id);
    }
}
